home *** CD-ROM | disk | FTP | other *** search
/ PC for Alla 2005 May / PC för Alla 0505.iso / fullversioner / realsoft3d / data1.cab / Scripting / scripts / js / oops / r3model.js < prev    next >
Encoding:
JavaScript  |  2005-04-04  |  2.0 KB  |  73 lines

  1.  
  2. // JavaScript wrapper for r3model.h
  3. // Auto generated file, do not modify by hand
  4. // Copyright ⌐ 2004, Realsoft Graphics Oy
  5.  
  6. var R3_MODEL_H = 1;
  7. include("oops/r3root.js")
  8.  
  9.  
  10. var R3CLID_MODEL = 6;
  11.  
  12.  
  13.  
  14.  
  15. // Description: Insert dependant to the models dependant list. Typically dependant acts as 'view' of model-view
  16. //      concept. When one of the attributes of the model is changed, R3RM_UPDATE is sent to
  17. //      the all dependants of the model. The p3 parameter associated with the R3RM_UPDATE method identifies
  18. //      the attribute changed. The p2 parameter associated with the R3RM_UPDATE method identifies the model identifier
  19. //      that has been given as parameter p2 with the R3MM_ADDDEPENDENT method.
  20. // Returns: Boolean, TRUE if succesfully inserted
  21. // p1: Integer, flags
  22. // p2: Integer, model identifier
  23. // p3: Object, address of the dependant
  24.  
  25. R3MM_ADDDEPENDENT = 6000;
  26.  
  27. function mR3MM_ADDDEPENDENT(p1, p2, p3) {
  28.   return   DoA3(this.r3obj, 6000, p1, R3TID_INTEGER, 0, p2, R3TID_INTEGER, 0, p3, R3TID_OBJECT, 0);
  29. }
  30.  
  31. // Description: Remove dependant (view) from models dependant list.
  32. // Returns: Boolean, TRUE if dependant was succesfully removed
  33. // p3: Object, dependant to be removed
  34.  
  35. R3MM_REMOVEDEPENDENT = 6001;
  36.  
  37. function mR3MM_REMOVEDEPENDENT(p3) {
  38.   return   DoA(this.r3obj, 6001, p3, R3TID_OBJECT, 0);
  39. }
  40.  
  41. // Description: Tell model that one of its state has changed. This causes the model object
  42. //      to send R3RM_UPDATE to all dependants.
  43. // p3: Tag[], tag list specifying attributes which has changed.
  44.  
  45. R3MM_CHANGED = 6002;
  46.  
  47. function mR3MM_CHANGED(p3) {
  48.   Do(this.r3obj, 6002, p3, R3TID_TAG, R3TNF_ARRAY);
  49. }
  50.  
  51.  
  52.  
  53.  
  54. var R3MF_SYNC = 1;
  55. var R3MF_NOUPDATE = 2;
  56. var R3MF_NOREF = 4;
  57.  
  58.  
  59. function r3Model () { 
  60.    this.base = r3God;
  61.    if(arguments.length) {
  62.       this.base(R3CLID_MODEL, arguments);
  63.    }
  64.    // Methods
  65.    this.ADDDEPENDENT=mR3MM_ADDDEPENDENT;
  66.    this.REMOVEDEPENDENT=mR3MM_REMOVEDEPENDENT;
  67.    this.CHANGED=mR3MM_CHANGED;
  68.  
  69.    // Attributes
  70. }
  71.  
  72. r3Model.prototype=new r3Root;
  73. // r3model.h_H